import {getlink} from "@/api/getapi.js"
export let menum={
    state: {
        data:null
      },
      mutations: {
        dataLoading(state,payload){
          // console.log(payload)
          state.data = payload
        }
      },
      actions: {
        menuData(context,payload){
          getlink(payload.url).then((ok)=>{
            // console.log(ok.data)
            context.commit("dataLoading",ok.data)
          }).catch((err)=>{
            console.log("失败",err)
          })
        }
      },
}